<?php defined('SEJUJOPEFDNGJSL') or exit('Access denied');?>
<div class="">
	<?php require("topbut.php") ?>
	<div class="panel panel-inverse">
        <div class="panel-heading">
            <h4 class="panel-title">静态明细</h4>
        </div>
        <div class="panel-body">
        	<div class="table-responsive">
	        	<table border="0" cellpadding="0" cellspacing="0" style="margin:0 auto;" class="table table-striped givetable" align="center" >
					  <tbody>
						<tr>
							<th>序号</th>
							<th>锁仓类型</th>
							<th>收益</th>
							<th>锁仓时间</th>
							<th>收益时间</th>
							<th>所属订单号</th>
							<!-- <th>锁仓类型</th> -->
							<th>锁仓数量</th>
							<th>套餐</th>
							
						</tr>
						<?php
						    if($_GET['pid']){
						    	$wheres=" and help_id=".intval($_GET['pid']);
						    }
							$xuhao=0;
							 $pagecount=10;
                             $condition=" where uid='".$_userid."'  and prize_option = 51".$wheres;
                             $psql="select count(0) from ld_prize_list $condition";
                             $db->query($psql,3);
                             $pcount=$db->fval;
                             $pagecount=$pagecount;   //每页条数
                             $astr="&lsact=lixilist";    //Url
                             $pagearr=pagelist($pagecount,$pcount,$astr);
                             $offset=$pagearr[1];

							$db->query("select * from ld_prize_list   where prize_option = 51   and uid = ".$_userid." $wheres  order by id desc limit $offset,$pagecount");
						    $combine_arr=$db->rs;
							if(!empty($combine_arr)){
								foreach($combine_arr as $k=> $v){
									$xuhao++;
									$give_help_info = give_get_help('give',$v['help_id'],'','');
									$give_help_no = $give_help_info['give_help_no'];
									$bianhao = substr($give_help_no,-14);
									if($v['prize_status']==1){
										$yanse="<font color='green'>";
										$des="已转入";
									}else{
										$yanse="<font color='red'>";
										$des="冻结";
									}

									if($give_help_info['xf_type']==1){
										$tmparr['jylx'] = "VIC收益";
									}elseif($give_help_info['xf_type']==2){
										$tmparr['jylx'] = "锁仓收益";
									}elseif($give_help_info['xf_type']==3){
										$tmparr['jylx'] = "团队收益";
									}else{
										$tmparr['jylx'] = "锁仓收益";
									}

							?>
								<tr>
									<td><?php echo $xuhao; ?></td>
									<td><?php echo $tmparr['jylx']; ?></td>
									<td ><?php echo $yanse.$v['amount']; ?></font> VIC</td>
									<td><?php echo date("Y-m-d H:i:s",$give_help_info['give_help_time']); ?></td>
									<td><?php echo date("Y-m-d H:i:s",$v['prize_ltime']); ?></td>
									<td><?php echo "T".encorder($bianhao); ?></td>
									
									<td ><?php echo $give_help_info['amount']; ?></td>
									<td><?php echo $give_help_info['tctype']; ?>套餐</td>
									
								</tr>
							<?php
								}
							}
							?>
					</tbody>
				</table>
			</div>
           <?php if(($pcount/$pagecount)>1){?>
           <div class="pagediv"><?php echo $pagearr[0]?></div>
           <?php }?>
           <?php if($pcount==0){?>
           <div class="pagediv" style="text-align:center;color:#E47501">--> 暂无数据</div>

           <?php
           }

           ?>
           <?php
           // echo "冻结1代领导奖:".$r['fir_freezedldj'];echo "&nbsp&nbsp冻结2代领导奖:".$r['sec_freezedldj'];echo "&nbsp&nbsp冻结4代领导奖:".$r['four_freezedldj'];
           ?>
        </div>
    </div>
</div>
<script type="text/javascript" src="theme/js/layer/layer.js"></script>
